package com.hqyj.hrms.modules.personnel.controller;


import com.hqyj.hrms.modules.personnel.entity.Contract;
import com.hqyj.hrms.modules.personnel.entity.Transfer;
import com.hqyj.hrms.modules.personnel.service.ContractService;
import com.hqyj.hrms.modules.personnel.service.TransferService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author rock
 * @since 2021-09-26
 */
@RestController
@RequestMapping("/transfer")
public class TransferController {
    @Autowired
    TransferService transferService;

    //查询
    @GetMapping("/list")
    public HashMap<String, Object> list(Transfer transfer) {
        return transferService.list(transfer);
    }

    @GetMapping("/add")
    public HashMap<String, Object> add(Transfer transfer) {
        return transferService.add(transfer);
    }

    @GetMapping("/update")
    public HashMap<String, Object> update(Transfer transfer) {
        return transferService.update(transfer);
    }

    @GetMapping("/del")
    public HashMap<String, Object> del(Integer id) {
        return transferService.del(id);
    }
}

